package cj.web.yc.service;
/*
 *  
 *  
*/
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import cj.web.yc.dao.PointLogDAO;
import cj.web.yc.domain.PointLog;

/**
 * 
 * @author 
 *
 */
@Service
public class PointLogService{

	@Autowired
    private PointLogDAO pointLogDAO;
	
	/**
	 * 查询
	 * @param pointLog
	 * @return pointLoglis;size
	 */
	public Map query(PointLog pointLog){
		Map rep = new HashMap();
		List<PointLog> pointLoglis = pointLogDAO.query(pointLog);
		int size = pointLogDAO.querySize(pointLog); 
		rep.put("pointLoglis", pointLoglis);
		rep.put("size", size);
		return rep;
    }
	
	public PointLog queryById(int id){
		PointLog obj = pointLogDAO.queryById(id);
		return obj;
    }
	
	public void create(PointLog pointLog){
		pointLogDAO.create(pointLog);
	}
	
	public void deleteById(int id){
		pointLogDAO.deleteById(id);
	}
}